<!--
 * @Date: 2023-09-09 14:49:5
 * @LastEditTime: 2023-12-04 10:15:14
 * @Description: content
-->
<template>
  <uni-popup ref="_priv_pop" type="center" :mask-click="false">
    <view class="_priv_pop">
      <view class="_priv_pop_bd_title">隐私保护指引</view>

      <view class="_priv_pop_bd_content">
        感谢选择我们的产品,我们非常重视您的个人信息安全和隐私保护.根据最新法律要求,使用我们的产品前,请仔细阅读
        <text @click="$c.to({ url: '/pages/guize/guize?type=5' })">
          《简单模玩隐私保护指引》
        </text>
        ,以便我们向您提供更优质的服务!
      </view>

      <view class="_priv_pop_bd_content">
        我们将尽全力保护您的个人信息及合法权益,感谢您的信任!
      </view>

      <view class="_priv_pop_ft">
        <view
          class="_priv_pop_ft_btn c_bg"
          :style="{
            backgroundImage: `url(${$img('/static/img2/cc29.png')})`
          }"
        >
          <navigator
            class="hide"
            open-type="exit"
            target="miniProgram"
          ></navigator>

          拒绝
        </view>

        <view
          @click="confirm"
          class="_priv_pop_ft_btn confirm c_bg"
          :style="{
            backgroundImage: `url(${$img('/static/img2/cc53.png')})`
          }"
        >
          同意
        </view>
      </view>
    </view>
  </uni-popup>
</template>

<script>
export default {
  data() {
    return {}
  },

  mounted() {
    const agree = uni.getStorageSync('_agree_priv')
    if (!agree) this.$refs._priv_pop.open()
  },

  methods: {
    confirm() {
      this.$refs._priv_pop.close()
      uni.setStorageSync('_agree_priv', true)
    }
  }
}
</script>

<style lang="scss">
._priv_pop {
  width: 600rpx;
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  padding: 0 50rpx;
  background: #222222;
  border: 4rpx solid #e40d1d;

  ._priv_pop_bd_title {
    padding: 40rpx 0 40rpx;
    text-align: center;

    font-family: 光良酒-干杯体, 光良酒-干杯体;
    font-weight: 400;
    font-size: 36rpx;
    color: #ffffff;
    text-shadow: 0 0 2px #e40d1d, 0 0 2px #e40d1d, 0 0 2px #e40d1d,
      0 0 2px #e40d1d;
  }

  ._priv_pop_bd_content {
    color: #aaa;
    font-size: 26rpx;
    line-height: 1.7;

    text {
      color: #e40d1d;
    }
  }

  ._priv_pop_ft {
    display: flex;
    justify-content: space-between;
    padding: 50rpx 0;

    ._priv_pop_ft_btn {
      width: 210rpx;
      height: 70rpx;
      display: flex;
      justify-content: center;
      align-items: center;
      position: relative;
      filter: grayscale(1);

      font-family: 光良酒-干杯体, 光良酒-干杯体;
      font-weight: 400;
      font-size: 32rpx;
      color: #ffffff;
      text-shadow: 0 0 2px #000000, 0 0 2px #000000, 0 0 2px #000000,
        0 0 2px #000000;

      .hide {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        height: 100%;
        opacity: 0;
        z-index: 1;
      }

      &.confirm {
        width: 220rpx;
        z-index: 1;
        border: 0;
        filter: grayscale(0);

        color: #fff;
      }
    }
  }
}
</style>
